﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;


using System.Management.Automation;

using CrystalDecisions.Enterprise.Desktop;

namespace BO.Management.PowerShell
{


    [Cmdlet(VerbsCommon.Get, "AuditEvents")]
    public class GetAuditEvents : BaseActionObject<ServerProvider, Server>
    {

        public override ServerProvider GetProvider()
        {
            return new ServerProvider(this.LogonProvider);
        }

        public override void WorkWithSingleObject(Server boeObject)
        {
            WriteObject(boeObject);

            this.WriteObject(boeObject.AdminServiceNames);
        }

        public override void WorkWithListObjects(List<Server> boeObjects)
        {
            foreach (Server server in boeObjects)
            {
                this.WorkWithSingleObject(server);
            }
        }
    }

}
